package pe.com.empresa.datos.dominio;

import java.util.ArrayList;
import java.util.List;

public class DominioExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public DominioExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andIdDominioIsNull() {
            addCriterion("idDominio is null");
            return (Criteria) this;
        }

        public Criteria andIdDominioIsNotNull() {
            addCriterion("idDominio is not null");
            return (Criteria) this;
        }

        public Criteria andIdDominioEqualTo(Integer value) {
            addCriterion("idDominio =", value, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioNotEqualTo(Integer value) {
            addCriterion("idDominio <>", value, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioGreaterThan(Integer value) {
            addCriterion("idDominio >", value, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioGreaterThanOrEqualTo(Integer value) {
            addCriterion("idDominio >=", value, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioLessThan(Integer value) {
            addCriterion("idDominio <", value, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioLessThanOrEqualTo(Integer value) {
            addCriterion("idDominio <=", value, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioIn(List<Integer> values) {
            addCriterion("idDominio in", values, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioNotIn(List<Integer> values) {
            addCriterion("idDominio not in", values, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioBetween(Integer value1, Integer value2) {
            addCriterion("idDominio between", value1, value2, "idDominio");
            return (Criteria) this;
        }

        public Criteria andIdDominioNotBetween(Integer value1, Integer value2) {
            addCriterion("idDominio not between", value1, value2, "idDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioIsNull() {
            addCriterion("descripcionDominio is null");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioIsNotNull() {
            addCriterion("descripcionDominio is not null");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioEqualTo(String value) {
            addCriterion("descripcionDominio =", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioNotEqualTo(String value) {
            addCriterion("descripcionDominio <>", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioGreaterThan(String value) {
            addCriterion("descripcionDominio >", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioGreaterThanOrEqualTo(String value) {
            addCriterion("descripcionDominio >=", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioLessThan(String value) {
            addCriterion("descripcionDominio <", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioLessThanOrEqualTo(String value) {
            addCriterion("descripcionDominio <=", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioLike(String value) {
            addCriterion("descripcionDominio like", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioNotLike(String value) {
            addCriterion("descripcionDominio not like", value, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioIn(List<String> values) {
            addCriterion("descripcionDominio in", values, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioNotIn(List<String> values) {
            addCriterion("descripcionDominio not in", values, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioBetween(String value1, String value2) {
            addCriterion("descripcionDominio between", value1, value2, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andDescripcionDominioNotBetween(String value1, String value2) {
            addCriterion("descripcionDominio not between", value1, value2, "descripcionDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioIsNull() {
            addCriterion("valorDominio is null");
            return (Criteria) this;
        }

        public Criteria andValorDominioIsNotNull() {
            addCriterion("valorDominio is not null");
            return (Criteria) this;
        }

        public Criteria andValorDominioEqualTo(String value) {
            addCriterion("valorDominio =", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioNotEqualTo(String value) {
            addCriterion("valorDominio <>", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioGreaterThan(String value) {
            addCriterion("valorDominio >", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioGreaterThanOrEqualTo(String value) {
            addCriterion("valorDominio >=", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioLessThan(String value) {
            addCriterion("valorDominio <", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioLessThanOrEqualTo(String value) {
            addCriterion("valorDominio <=", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioLike(String value) {
            addCriterion("valorDominio like", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioNotLike(String value) {
            addCriterion("valorDominio not like", value, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioIn(List<String> values) {
            addCriterion("valorDominio in", values, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioNotIn(List<String> values) {
            addCriterion("valorDominio not in", values, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioBetween(String value1, String value2) {
            addCriterion("valorDominio between", value1, value2, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andValorDominioNotBetween(String value1, String value2) {
            addCriterion("valorDominio not between", value1, value2, "valorDominio");
            return (Criteria) this;
        }

        public Criteria andEstadoIsNull() {
            addCriterion("estado is null");
            return (Criteria) this;
        }

        public Criteria andEstadoIsNotNull() {
            addCriterion("estado is not null");
            return (Criteria) this;
        }

        public Criteria andEstadoEqualTo(String value) {
            addCriterion("estado =", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoNotEqualTo(String value) {
            addCriterion("estado <>", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoGreaterThan(String value) {
            addCriterion("estado >", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoGreaterThanOrEqualTo(String value) {
            addCriterion("estado >=", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoLessThan(String value) {
            addCriterion("estado <", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoLessThanOrEqualTo(String value) {
            addCriterion("estado <=", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoLike(String value) {
            addCriterion("estado like", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoNotLike(String value) {
            addCriterion("estado not like", value, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoIn(List<String> values) {
            addCriterion("estado in", values, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoNotIn(List<String> values) {
            addCriterion("estado not in", values, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoBetween(String value1, String value2) {
            addCriterion("estado between", value1, value2, "estado");
            return (Criteria) this;
        }

        public Criteria andEstadoNotBetween(String value1, String value2) {
            addCriterion("estado not between", value1, value2, "estado");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroIsNull() {
            addCriterion("fechaRegistro is null");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroIsNotNull() {
            addCriterion("fechaRegistro is not null");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroEqualTo(String value) {
            addCriterion("fechaRegistro =", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroNotEqualTo(String value) {
            addCriterion("fechaRegistro <>", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroGreaterThan(String value) {
            addCriterion("fechaRegistro >", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroGreaterThanOrEqualTo(String value) {
            addCriterion("fechaRegistro >=", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroLessThan(String value) {
            addCriterion("fechaRegistro <", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroLessThanOrEqualTo(String value) {
            addCriterion("fechaRegistro <=", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroLike(String value) {
            addCriterion("fechaRegistro like", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroNotLike(String value) {
            addCriterion("fechaRegistro not like", value, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroIn(List<String> values) {
            addCriterion("fechaRegistro in", values, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroNotIn(List<String> values) {
            addCriterion("fechaRegistro not in", values, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroBetween(String value1, String value2) {
            addCriterion("fechaRegistro between", value1, value2, "fechaRegistro");
            return (Criteria) this;
        }

        public Criteria andFechaRegistroNotBetween(String value1, String value2) {
            addCriterion("fechaRegistro not between", value1, value2, "fechaRegistro");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}